package com.newlink.building.userinfo.mvp.model

import com.newlink.building.common_base.base.BaseModel
import com.newlink.building.common_base.http.Base_RetrofitHelper
import com.newlink.building.common_base.model.bean.*
import com.newlink.building.common_base.utils.NLog
import com.newlink.building.userinfo.mvp.contract.Module_UserInfo_LocalMsgContract
import io.reactivex.Observable

/**
 * @Author: Jake
 * @Date: 2023-12-11
 * @Description:
 */
class Module_UserInfo_LocalMsgModel : BaseModel(), Module_UserInfo_LocalMsgContract.Model {

    override fun deleteAllMessageList(request: MessageCleanRequest): Observable<HttpResult<DefaultData>> {
//        KcpTaskHelper.instance.requestMessageClean(request)
        return Base_RetrofitHelper.service.deleteAllMessageList(request.accessToken)
    }

    override fun getMessageList(request: MessageListRequest): Observable<HttpResult<MessageListData>> {
        NLog.e("<Jake> .....getMessageList ::: $request ")
        return Base_RetrofitHelper.service.getMessageList(
            request.accessToken,
            request.page,
            request.limit
        )
    }

}